//
//  MyButton.swift
//  demo01
//
//  Created by babybus on 2025/6/27.
//

import Foundation
import UIKit

class MyButton:UIButton{
    override init(frame: CGRect) {
        super.init(frame: frame)
        setupUI()
    }
    required init?(coder: NSCoder) {
        fatalError("init(coder:) has not been implemented")
    }
    
    func setupUI(){
        
    }
    
    func configure(title:String?,titleFor:UIControl.State,titleColor:UIColor,titleColorFor:UIControl.State,
                   backgroundColor:UIColor){
        self.setTitle(title, for: titleFor)
        self.setTitleColor(titleColor, for: titleColorFor)
        self.backgroundColor = backgroundColor
    }
}
